const { CHANGE_NAME, ADD_COUNTER } = require('./constants')

// actionCreateors:帮助我们创建action
function changeNameAction(name) {
  return {
    type: CHANGE_NAME,
    name,
  }
}

function changeCounterAction(num) {
  return {
    type: ADD_COUNTER,
    num,
  }
}

module.exports = {
  changeCounterAction,
  changeNameAction,
}
